﻿namespace ACCOUNTING
{
    using ACCOUNTING.LVY.Business;
    using Microsoft.VisualBasic.CompilerServices;
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Diagnostics;
    using System.Drawing;
    using System.Runtime.CompilerServices;
    using System.Windows.Forms;

    [DesignerGenerated]
    public class Frm_GhiSoXuatKho : Form
    {
        private static List<WeakReference> __ENCList = new List<WeakReference>();
        [AccessedThroughProperty("AdvTaiKhoanChu")]
        private ADVAccount _AdvTaiKhoanChu;
        [AccessedThroughProperty("CmdCancel")]
        private Button _CmdCancel;
        [AccessedThroughProperty("CmdOK")]
        private Button _CmdOK;
        [AccessedThroughProperty("GroupBox1")]
        private GroupBox _GroupBox1;
        [AccessedThroughProperty("Label2")]
        private Label _Label2;
        public string cFrmKhoa;
        private IContainer components;
        private bool mGhiSo;
        private clsXuatKho objHD;

        public Frm_GhiSoXuatKho()
        {
            base.Load += new EventHandler(this.Frm_DinhKhoanNhapKhau_Load);
            List<WeakReference> list = __ENCList;
            lock (list)
            {
                __ENCList.Add(new WeakReference(this));
            }
            this.objHD = new clsXuatKho();
            this.cFrmKhoa = "";
            this.mGhiSo = false;
            this.InitializeComponent();
        }

        public bool CheckIvalidRegister()
        {
            if (this.AdvTaiKhoanChu.Value == "")
            {
                LVYModule.ShowWarning(modGeneral.Tranlated("Bạn phải nhập t\x00e0i khoản thanh to\x00e1n!", ""));
                this.AdvTaiKhoanChu.Focus();
                return false;
            }
            return true;
        }

        private void CmdCancel_Click(object sender, EventArgs e)
        {
            this.Dispose();
        }

        private void CmdOK_Click(object sender, EventArgs e)
        {
            if (this.CheckIvalidRegister() && this.objHD.Registered(this.cFrmKhoa, this.AdvTaiKhoanChu.Value, "", "", ""))
            {
                this.mGhiSo = true;
                this.Close();
            }
        }

        [DebuggerNonUserCode]
        protected override void Dispose(bool disposing)
        {
            if (disposing && (this.components != null))
            {
                this.components.Dispose();
            }
            base.Dispose(disposing);
        }

        private void Frm_DinhKhoanNhapKhau_Load(object sender, EventArgs e)
        {
            this.objHD.Load(this.cFrmKhoa);
            if (this.objHD.KhoaTKThanhToan.Trim() != "")
            {
                this.AdvTaiKhoanChu.Value = this.objHD.KhoaTKThanhToan;
            }
        }

        [DebuggerStepThrough]
        private void InitializeComponent()
        {
            ComponentResourceManager manager = new ComponentResourceManager(typeof(Frm_GhiSoXuatKho));
            this.Label2 = new Label();
            this.GroupBox1 = new GroupBox();
            this.CmdCancel = new Button();
            this.CmdOK = new Button();
            this.AdvTaiKhoanChu = new ADVAccount();
            this.GroupBox1.SuspendLayout();
            this.SuspendLayout();
            this.Label2.AutoSize = true;
            Point point = new Point(20, 0x24);
            this.Label2.Location = point;
            this.Label2.Name = "Label2";
            Size size = new Size(70, 13);
            this.Label2.Size = size;
            this.Label2.TabIndex = 0x8b;
            this.Label2.Text = "T\x00e0i khoản nợ";
            this.GroupBox1.Controls.Add(this.Label2);
            this.GroupBox1.Controls.Add(this.AdvTaiKhoanChu);
            point = new Point(4, 3);
            this.GroupBox1.Location = point;
            this.GroupBox1.Name = "GroupBox1";
            size = new Size(0x197, 100);
            this.GroupBox1.Size = size;
            this.GroupBox1.TabIndex = 13;
            this.GroupBox1.TabStop = false;
            this.GroupBox1.Text = "Định khoản";
            this.CmdCancel.DialogResult = DialogResult.Cancel;
            this.CmdCancel.Image = (Image) manager.GetObject("CmdCancel.Image");
            this.CmdCancel.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(0x14c, 0x6d);
            this.CmdCancel.Location = point;
            this.CmdCancel.Name = "CmdCancel";
            size = new Size(0x4f, 0x18);
            this.CmdCancel.Size = size;
            this.CmdCancel.TabIndex = 15;
            this.CmdCancel.Text = "&Tho\x00e1t";
            this.CmdCancel.UseVisualStyleBackColor = true;
            this.CmdOK.Image = (Image) manager.GetObject("CmdOK.Image");
            this.CmdOK.ImageAlign = ContentAlignment.MiddleLeft;
            point = new Point(0xf8, 0x6d);
            this.CmdOK.Location = point;
            this.CmdOK.Name = "CmdOK";
            size = new Size(0x4e, 0x18);
            this.CmdOK.Size = size;
            this.CmdOK.TabIndex = 14;
            this.CmdOK.Text = "&Chọn";
            this.CmdOK.UseVisualStyleBackColor = true;
            this.AdvTaiKhoanChu.Conditions = "";
            this.AdvTaiKhoanChu.FieldNameFilter = "Left(SoTaiKhoan,1)";
            this.AdvTaiKhoanChu.KeyFilter = "6";
            point = new Point(0x69, 0x20);
            this.AdvTaiKhoanChu.Location = point;
            Padding padding = new Padding(0);
            this.AdvTaiKhoanChu.Margin = padding;
            this.AdvTaiKhoanChu.Name = "AdvTaiKhoanChu";
            this.AdvTaiKhoanChu.OnlyDigit = false;
            this.AdvTaiKhoanChu.ReadOnly = false;
            size = new Size(0x121, 20);
            this.AdvTaiKhoanChu.Size = size;
            this.AdvTaiKhoanChu.TabIndex = 0x89;
            this.AdvTaiKhoanChu.UpperText = true;
            this.AdvTaiKhoanChu.Value = "";
            this.AdvTaiKhoanChu.WithCode = 80;
            SizeF ef = new SizeF(6f, 13f);
            this.AutoScaleDimensions = ef;
            this.AutoScaleMode = AutoScaleMode.Font;
            size = new Size(0x1a1, 0x8a);
            this.ClientSize = size;
            this.ControlBox = false;
            this.Controls.Add(this.CmdCancel);
            this.Controls.Add(this.CmdOK);
            this.Controls.Add(this.GroupBox1);
            this.FormBorderStyle = FormBorderStyle.FixedDialog;
            this.Name = "Frm_GhiSoXuatKho";
            this.StartPosition = FormStartPosition.CenterScreen;
            this.Text = "GHI SO XUAT KHO";
            this.GroupBox1.ResumeLayout(false);
            this.GroupBox1.PerformLayout();
            this.ResumeLayout(false);
        }

        internal virtual ADVAccount AdvTaiKhoanChu
        {
            [DebuggerNonUserCode]
            get
            {
                return this._AdvTaiKhoanChu;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._AdvTaiKhoanChu = value;
            }
        }

        internal virtual Button CmdCancel
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdCancel;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdCancel_Click);
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click -= handler;
                }
                this._CmdCancel = value;
                if (this._CmdCancel != null)
                {
                    this._CmdCancel.Click += handler;
                }
            }
        }

        internal virtual Button CmdOK
        {
            [DebuggerNonUserCode]
            get
            {
                return this._CmdOK;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                EventHandler handler = new EventHandler(this.CmdOK_Click);
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click -= handler;
                }
                this._CmdOK = value;
                if (this._CmdOK != null)
                {
                    this._CmdOK.Click += handler;
                }
            }
        }

        public bool GhiSo
        {
            get
            {
                return this.mGhiSo;
            }
            set
            {
                this.mGhiSo = value;
            }
        }

        internal virtual GroupBox GroupBox1
        {
            [DebuggerNonUserCode]
            get
            {
                return this._GroupBox1;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._GroupBox1 = value;
            }
        }

        internal virtual Label Label2
        {
            [DebuggerNonUserCode]
            get
            {
                return this._Label2;
            }
            [MethodImpl(MethodImplOptions.Synchronized), DebuggerNonUserCode]
            set
            {
                this._Label2 = value;
            }
        }
    }
}

